// app的配置信息

export const uri_name = 'sys-config'; // 替换文件名称

export async function main(req, reply) {
  let db_config = this.mongo.db.collection('sys_config');
  let cnfs =  await db_config.find({}).toArray();
  let cnf = cnfs.reduce((o, v) => {
    o[v.key] = v.value;
    return o;
  }, {});
  return cnf;
};
